3.222 \(\int \frac{\sqrt{a+a \cos (e+f x)}}{\sqrt{\cos (e+f x)}} \, dx\)

Optimal. Leaf size=37 \[ \frac{2 \sqrt{a} \sin ^{-1}\left (\frac{\sqrt{a} \sin (e+f x)}{\sqrt{a \cos (e+f x)+a}}\right )}{f} \]

[Out]

(2*Sqrt[a]*ArcSin[(Sqrt[a]*Sin[e + f*x])/Sqrt[a + a*Cos[e + f*x]]])/f

________________________________________________________________________________________

Rubi [A]  time = 0.0597373, antiderivative size = 37, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 25, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.08, Rules used = {2774, 216} \[ \frac{2 \sqrt{a} \sin ^{-1}\left (\frac{\sqrt{a} \sin (e+f x)}{\sqrt{a \cos (e+f x)+a}}\right )}{f} \]

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + a*Cos[e + f*x]]/Sqrt[Cos[e + f*x]],x]

[Out]

(2*Sqrt[a]*ArcSin[(Sqrt[a]*Sin[e + f*x])/Sqrt[a + a*Cos[e + f*x]]])/f

Rule 2774

Int[Sqrt[(a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]]/Sqrt[(d_.)*sin[(e_.) + (f_.)*(x_)]], x_Symbol] :> Dist[-2/f, Su
bst[Int[1/Sqrt[1 - x^2/a], x], x, (b*Cos[e + f*x])/Sqrt[a + b*Sin[e + f*x]]], x] /; FreeQ[{a, b, d, e, f}, x]
&& EqQ[a^2 - b^2, 0] && EqQ[d, a/b]

Rule 216

Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Simp[ArcSin[(Rt[-b, 2]*x)/Sqrt[a]]/Rt[-b, 2], x] /; FreeQ[{a, b}
, x] && GtQ[a, 0] && NegQ[b]

Rubi steps

\begin{align*} \int \frac{\sqrt{a+a \cos (e+f x)}}{\sqrt{\cos (e+f x)}} \, dx &=-\frac{2 \operatorname{Subst}\left (\int \frac{1}{\sqrt{1-\frac{x^2}{a}}} \, dx,x,-\frac{a \sin (e+f x)}{\sqrt{a+a \cos (e+f x)}}\right )}{f}\\ &=\frac{2 \sqrt{a} \sin ^{-1}\left (\frac{\sqrt{a} \sin (e+f x)}{\sqrt{a+a \cos (e+f x)}}\right )}{f}\\ \end{align*}

Mathematica [A]  time = 0.0643995, size = 50, normalized size = 1.35 \[ \frac{\sqrt{2} \sin ^{-1}\left (\sqrt{2} \sin \left (\frac{1}{2} (e+f x)\right )\right ) \sec \left (\frac{1}{2} (e+f x)\right ) \sqrt{a (\cos (e+f x)+1)}}{f} \]

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + a*Cos[e + f*x]]/Sqrt[Cos[e + f*x]],x]

[Out]

(Sqrt[2]*ArcSin[Sqrt[2]*Sin[(e + f*x)/2]]*Sqrt[a*(1 + Cos[e + f*x])]*Sec[(e + f*x)/2])/f

________________________________________________________________________________________

Maple [B]  time = 0.392, size = 80, normalized size = 2.2 \begin{align*} 2\,{\frac{\sqrt{a \left ( \cos \left ( fx+e \right ) +1 \right ) }}{f\sqrt{\cos \left ( fx+e \right ) }}\sqrt{{\frac{\cos \left ( fx+e \right ) }{\cos \left ( fx+e \right ) +1}}}\arctan \left ({\frac{\sin \left ( fx+e \right ) }{\cos \left ( fx+e \right ) }\sqrt{{\frac{\cos \left ( fx+e \right ) }{\cos \left ( fx+e \right ) +1}}}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*cos(f*x+e))^(1/2)/cos(f*x+e)^(1/2),x)

[Out]

2/f/cos(f*x+e)^(1/2)*(cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*(a*(cos(f*x+e)+1))^(1/2)*arctan(sin(f*x+e)*(cos(f*x+e)/
(cos(f*x+e)+1))^(1/2)/cos(f*x+e))

________________________________________________________________________________________

Maxima [B]  time = 1.79942, size = 197, normalized size = 5.32 \begin{align*} \frac{\sqrt{a} \arctan \left ({\left (\cos \left (2 \, f x + 2 \, e\right )^{2} + \sin \left (2 \, f x + 2 \, e\right )^{2} + 2 \, \cos \left (2 \, f x + 2 \, e\right ) + 1\right )}^{\frac{1}{4}} \sin \left (\frac{1}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right ) + 1\right )\right ) + \sin \left (f x + e\right ),{\left (\cos \left (2 \, f x + 2 \, e\right )^{2} + \sin \left (2 \, f x + 2 \, e\right )^{2} + 2 \, \cos \left (2 \, f x + 2 \, e\right ) + 1\right )}^{\frac{1}{4}} \cos \left (\frac{1}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right ) + 1\right )\right ) + \cos \left (f x + e\right )\right )}{f} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(f*x+e))^(1/2)/cos(f*x+e)^(1/2),x, algorithm="maxima")

[Out]

sqrt(a)*arctan2((cos(2*f*x + 2*e)^2 + sin(2*f*x + 2*e)^2 + 2*cos(2*f*x + 2*e) + 1)^(1/4)*sin(1/2*arctan2(sin(2
*f*x + 2*e), cos(2*f*x + 2*e) + 1)) + sin(f*x + e), (cos(2*f*x + 2*e)^2 + sin(2*f*x + 2*e)^2 + 2*cos(2*f*x + 2
*e) + 1)^(1/4)*cos(1/2*arctan2(sin(2*f*x + 2*e), cos(2*f*x + 2*e) + 1)) + cos(f*x + e))/f

________________________________________________________________________________________

Fricas [A]  time = 2.09459, size = 325, normalized size = 8.78 \begin{align*} \left [\frac{\sqrt{-a} \log \left (\frac{2 \, a \cos \left (f x + e\right )^{2} - 2 \, \sqrt{a \cos \left (f x + e\right ) + a} \sqrt{-a} \sqrt{\cos \left (f x + e\right )} \sin \left (f x + e\right ) + a \cos \left (f x + e\right ) - a}{\cos \left (f x + e\right ) + 1}\right )}{f}, -\frac{2 \, \sqrt{a} \arctan \left (\frac{\sqrt{a \cos \left (f x + e\right ) + a} \sqrt{\cos \left (f x + e\right )}}{\sqrt{a} \sin \left (f x + e\right )}\right )}{f}\right ] \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(f*x+e))^(1/2)/cos(f*x+e)^(1/2),x, algorithm="fricas")

[Out]

[sqrt(-a)*log((2*a*cos(f*x + e)^2 - 2*sqrt(a*cos(f*x + e) + a)*sqrt(-a)*sqrt(cos(f*x + e))*sin(f*x + e) + a*co
s(f*x + e) - a)/(cos(f*x + e) + 1))/f, -2*sqrt(a)*arctan(sqrt(a*cos(f*x + e) + a)*sqrt(cos(f*x + e))/(sqrt(a)*
sin(f*x + e)))/f]

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{a \left (\cos{\left (e + f x \right )} + 1\right )}}{\sqrt{\cos{\left (e + f x \right )}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(f*x+e))**(1/2)/cos(f*x+e)**(1/2),x)

[Out]

Integral(sqrt(a*(cos(e + f*x) + 1))/sqrt(cos(e + f*x)), x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{a \cos \left (f x + e\right ) + a}}{\sqrt{\cos \left (f x + e\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(f*x+e))^(1/2)/cos(f*x+e)^(1/2),x, algorithm="giac")

[Out]

integrate(sqrt(a*cos(f*x + e) + a)/sqrt(cos(f*x + e)), x)